package main

import (
	"fmt"
	"sync"
	"time"
)

func main() {
	start := time.Now().UnixMilli()
	var cc sync.WaitGroup
	cc.Add(50)
	uid := 100
	for i := 0; i < 50; i++ {
		uid++
		if uid > 109 {
			uid = uid - 10
		}
		go func(uid int) {
			goods := comm.AddGoods(1001, uid)
			fmt.Println(goods)
			cc.Done()
		}(uid)
	}
	cc.Wait()
	fmt.Println(time.Now().UnixMilli() - start)
}


10
31
41
393
387
291
51
431
461
433
33
509
253
216
403
419